<?php

{$AUTO_GENERATOR_INCLUDE_HEADER_TEMPLATE}

defined('_JEXEC') or die;

class {$AUTO_GENERATOR_COMPONENT|capitalize}View{$AUTO_GENERATOR_VIEW|capitalize} extends JViewLegacy {

    protected $form;
    protected $item;
    protected $state;

    public function display($tpl = null) {
        $this->form = $this->get('Form');
        $this->item = $this->get('Item');
        $this->state = $this->get('State');

        $this->addToolbar();

        parent::display($tpl);
    }

    protected function addToolbar() {
        JToolbarHelper::apply('{$AUTO_GENERATOR_CONTROLLER|lower}.apply');
        JToolbarHelper::save('{$AUTO_GENERATOR_CONTROLLER|lower}.save');
        JToolbarHelper::save2new('{$AUTO_GENERATOR_CONTROLLER|lower}.save2new');
        JToolbarHelper::cancel('{$AUTO_GENERATOR_CONTROLLER|lower}.cancel');
    }

}
